<div ng-show="menu.activeID=='sign'">
       <h1>1：用户登录</h1>
       <div ng-show="signState==1">
         <h2>登录信息</h2>
         <div class="pre">
          <p><strong>Token:</strong>{{signUser.token.substring(0,8)}}...<p>
          <p><strong>code:</strong>{{signUser.code}}<p>
          <p><strong>name:</strong>{{signUser.name}}<p>
          <button class="btn btn-danger" ng-click="signOut()">退出</button> 
         </div>
       </div>
       
       <div ng-show="signState==0||true">
         <h2>登录</h2>
           <div class="pre">
           <div class="form-group">
              <label >账号</label>
              <input  class="form-control"  placeholder="账号/手机号/邮箱" ng-Model="login.account">
             </div>           
             <div class="form-group">
              <label >密码</label>
              <input  type="password" class="form-control"  placeholder="Enter 密码" ng-Model="login.password">
             </div>
             <div>
               <button class="btn btn-danger" ng-click="sign()">登录</button>            
             </div>
         </div>         
       </div>
       

       <h2>调用方法</h2>
       <div class="pre">
           var requrl=站点+"/user/sign";<br>
           var Jsondata=<br>
           {<br>
           account:"user1",<br>
                         password:"123"<br>
                         }<br>
           $http.post(requrl, Jsondata).success(function (response) {<br>
            alert(response.message);<br>
          });<br><br><br><br>


          <strong>Jsondata 参数说明</strong><br>


          account:必填参数<br>
          password:必填参数<br>
          <strong>备注：account采用mail/手机号/用户名任何一个都可以登录</strong>
         </div>
       
        <h2>response:返回结果</h2>
        <div class="pre">
        <h3>返回结构</h3>
        {<br>
		    "result": true,<br>
		    "messageflag": 1,<br>
		    "message": "sign successfully.",<br>
		    "data": {<br>
		        "token": "GMo3P777DJmvzc",<br>
		        "name": "云哥",<br>
		        "code": "yunge"<br>
		 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;   }<br>
		}<br><br><br><br>
        <table class="table table-bordered">
          <tr><th>result</th><th>messageflag</th><th>message</th><th>data</th></tr>
          <tr><td>true</td><td>old_token</td><td>sign successfully.</td><td>{token:"",name:"",code:""}.</td></tr>
          <tr><td>true</td><td>new_token</td><td>sign successfully.</td><td>{token:"",name:"",code:""}.</td></tr>
           <tr><td>false</td><td>error</td><td>application error.</td><td>null</td></tr>          
          <tr><td>false</td><td>psd_incorrect</td><td>The password incorrect.</td><td>null</td></tr>
          <tr><td>false</td><td>code_incorrect</td><td>The user not exist.</td><td>null</td></tr>
          <tr><td>false</td><td>code_required</td><td>code is required.</td><td>null</td></tr>
          <tr><td>false</td><td>psd_required</td><td>password is required.</td><td>null</td></tr>
        </table>
        </div>
       <h1>2：用户注销</h1> 
       <h2>调用方法</h2>
       <div class="pre">
        $scope.signOut=function(){<br>
        var requrl ="site"+"/user/signOut?token="+$scope.signUser.token;<br>
        var Jsondata=null;<br>
        $http.post(requrl, Jsondata).success(function (response) {<br>
          alert(response);
        });<br>
     }     <br> <br> <br> 

     <strong>token </strong>url参数为必填
       </div>
       
       <h2>返回结果</h2>
       <div>
         <table class="table table-bordered">
          <tr><th>result</th><th>messageflag</th><th>message</th></tr>
          
          <tr><td>false</td><td>error</td><td>applicationt error.</td></tr>
          <tr><td>true</td><td>success</td><td>sign out successfully.</td></tr>
          <tr><td>false</td><td>token_required</td><td>the token is required.</td></tr>
         
        </table>
       </div>

       <h1>3：获取当前用户信息</h1> 
       <h2>调用方法</h2>
       <div class="pre">
        $scope.getSignUser=function(){<br>
        var requrl ="site"+"/user/getSignUser?token="+$scope.signUser.token;<br>
        var Jsondata=null;<br>
        $http.post(requrl, Jsondata).success(function (response) {<br>
          alert(response);
        });<br>
     }     <br> <br> <br> 

     <strong>token </strong>url参数为必填
       </div>
       
       <h2>返回结果</h2>
       <div class="pre">
       <strong>返回结构</strong><br>
       {<br>
    "result": true,<br>
    "messageflag": "success",<br>
    "message": "successfully.",<br>
    "data": {<br>
        "status": "active",<br>
        "companyName": "",<br>
        "companyCode": "",<br>
        "remark": "",<br>
        "address": "",<br>
        "phone": "13434545",<br>
        "telephone": "",<br>
        "mail": "yunge@sina.com",<br>
        "name": "云哥",<br>
        "code": "yunge"<br>
    }<br>
}<br><br><br>



        <table class="table table-bordered">
          <tr><th>result</th><th>messageflag</th><th>message</th><th>data</th></tr>
          <tr><td>true</td><td>success</td><td>sign successfully.</td><td>json对象</td></tr>
           <tr><td>false</td><td>error</td><td>application error.</td><td>null</td></tr>          
          <tr><td>false</td><td>token_required</td><td>The token is required.</td><td>null</td></tr>
          <tr><td>false</td><td>token_invalid</td><td>The token is Invalid.</td><td>null</td></tr>
        </table>

        <div>
         <button class="btn btn-danger" ng-click="user.getSignUser()">获取当前登录用户信息（测试）</button>
       </div>
       </div>
       

       <h1>用户上传头像</h1>
       <h2>调用方法</h2>
       <div class="pre">
         <button class="btn btn-danger" ng-click=" user.getIcon()">获取头像</button>
         <image src="http://localhost:3000/files/images/yeyu1.jpg" class="img-responsive img-rounded">
       </div>
       <h2>返回结果</h2>
       <div class="pre">
       <button class="btn btn-danger" ng-click="user.uploadIcon()">上传头像</button>
       <button class="btn btn-danger" ng-click="user.invokeProcData()">调用存储过程</button>
       
       </div>

</div>